package gov.nasa.anml;

import gov.nasa.anml.utility.SimpleObject;
import gov.nasa.anml.utility.iHashMap;
import gov.nasa.anml.utility.iHashMap.Entry;

//implements cloning of the values of the map.  History does a shallow clone.
public class iFunctionHistoryMap extends iHashMap<BindingHistoryMap<? extends SimpleObject<?>>> {
	public Entry<BindingHistoryMap<? extends SimpleObject<?>>> createEntry(int index, int key, BindingHistoryMap<? extends SimpleObject<?>> value) {
		Entry<BindingHistoryMap<? extends SimpleObject<?>>> e = table[index];
		table[index] = new Entry<BindingHistoryMap<? extends SimpleObject<?>>>(key, value.clone(), e);
		size++;
		return e;
	}
	public iFunctionHistoryMap clone() {
		return (iFunctionHistoryMap) super.clone();
	}
}

